﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Globalization;
using System.IO;
using System.Net;
using System.Linq;
using System.Text.RegularExpressions;
using BookDownloader.Core.Behaviour;
using BookDownloader.Core.Data;
using BookDownloader.Core.Implementation.BaseLibEngine;
using BookDownloader.Core.Implementation.BaseLibEngine.Parser;
using BookDownloader.Core.Implementation.Flibusta.Parser;

namespace BookDownloader.Core.Implementation.Flibusta
{
	public class FlibustaLibraryProvider : LibraryProviderBase
	{
		public FlibustaLibraryProvider(List<LibraryBook> library) : base(library)
		{
		}

		protected override void LoadData()
		{
			AuthorBooksParser abp =  new AuthorBooksParser(new SqlWebStreamProvider());
			abp.LoadList(LibFileTypes.AuthorBook, authorBooks);

			AuthorsParser ap = new AuthorsParser(new SqlWebStreamProvider());
			ap.LoadList(LibFileTypes.Author, authors);

			BooksParser bp = new BooksParser(new SqlWebStreamProvider());
			bp.LoadList(LibFileTypes.Book, books);

		}

	}
}
